/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package algorithm;

/**
 *
 * @author Lu
 */
public class Task implements Comparable<Task> {

    private int length;
    private int machine;
    private int product;

    public Task(int length, int machine, int product) {
        this.length = length;
        this.machine = machine;
        this.product = product;
    }

    public int getLength() {
        return length;
    }

    public int getMachine() {
        return machine;
    }

    public int getProduct() {
        return product;
    }

    public void setLength(int length) {
        this.length = length;
    }

    @Override
    public int compareTo(Task o) {
        return (o.length - this.length);
    }
}
